<template>
	<view class="content">
		<view class="info-block">
			<mp-html :content="detail.content"></mp-html>
		</view>
	</view>
</template>

<script>
	import {
		getTipsById
	} from '@/api/home.js'
	export default {
		data() {
			return {
				detail: {
					content: ''
				}
			}
		},
		methods: {
			getDetail() {
				uni.showLoading({
					title: '加载中',
					mask: true
				})
				getTipsById().then(data => {
					uni.hideLoading()
					this.detail = data;
				}).catch(() => {
					uni.hideLoading()
				})
			}
		},
		onLoad() {
			this.getDetail()
		}
	}
</script>

<style lang="scss">
	page {
		background: #F5F5F5;
	}

	.content {
		padding: 30rpx;

		.info-block {
			min-height: 80vh;
			display: flex;
			flex-direction: column;
			border-radius: 60rpx;
			background: url('../../static/clap/white-bg.png');
			background-repeat: no-repeat;
			background-color: #fff;
			padding: 30rpx;
			background-position: top right;
		}
	}
</style>